;;;HTML browser front end Suitable for inclusion in VLX applications
;;;primarily used to display html help files for ParaCADD's apps
;;;
;;;	AUTHOR:
;;;		HENRY C. FRANCIS
;;;		425 N. ASHE ST.
;;;		SOUTHERN PINES, NC 28387
;;;
;;;		All rights reserved.
;;;		http://www.paracadd.com/
;;;
;;;  Copyright:	1/27/2002
;;;     Edited:	4/21/2010
;;;
;;;****************************************************************************
  (if check_for_doslib
    NIL
    (LOAD "check_for_doslib" "\nFile CHECK_FOR_DOSLIB.LSP not loaded! ")
  )
  (check_for_doslib)  
  (vl-arx-import 'DOS_HTMLBOX)
;;;****************************************************************************
(defun helphtm (title fndfile / )
  (if dos_htmlbox
    (dos_htmlbox
      title
      fndfile
      1024
      760
    ) ;_ end of dos_htmlbox
    (progn
      (setq drvs '("C" "D" "E" "F" "G" "H" "I" "J" "K" "L" "M" "N"))
      (setq cnt 0)
      (while
        (and
          (< cnt (length drvs))
          (not (dos_dirp (strcat (NTH cnt drvs)
                                 ":\\Program Files (x86)\\Internet Explorer"
                         ) ;_ end of strcat
               ) ;_ end of dos_dirp
          ) ;_ end of not
          (not (dos_dirp (strcat (NTH cnt drvs)
                                 ":\\Program Files\\Internet Explorer"
                         ) ;_ end of strcat
               ) ;_ end of dos_dirp
          ) ;_ end of not
        ) ;_ end of and
         (setq cnt (1+ cnt))
      ) ;_ end of while
      (if (< cnt (length drvs))
        (progn
          (setq ielocation
              (COND
                ((findfile
                   (strcat
                     (nth cnt drvs)
                     ":/Program Files (x86)/Internet Explorer/iexplore.exe"
                   ) ;_ end of strcat
                 )) ;_ end of findfile
                ((findfile
                   (strcat
                     (nth cnt drvs)
                     ":/Program Files/Internet Explorer/iexplore.exe"
                   ) ;_ end of strcat
                 )) ;_ end of findfile
              )
          ) ;_ end of setq
	  (IF ielocation
            (startapp ielocation fndfile)
            (alert
              (strcat
                "Unable to locate a browser application!\nPlease launch your browser and open the help file: \""
                fndfile
                "\"."
              ) ;_ end of strcat
            ) ;_ end of alert
	  )
        ) ;_ end of progn
        (alert
          (strcat
            "Unable to locate a browser application!\nPlease launch your browser and open the help file: \""
            fndfile
            "\"."
          ) ;_ end of strcat
        ) ;_ end of alert
      ) ;_ end of if
    ) ;_ end of progn
  ) ;_ end of if
) ;_ end of defun
